#import <Foundation/Foundation.h>
#import <UIKit/UIKit.h>
#import <UIKit/UIApplication.h>
#import <UIKit/UIPushButton.h>
#import <UIKit/UINavigationBar.h>
#import <UIKit/UIImageAndTextTableCell.h>
#import <UIKit/UITransitionView.h>
#import <UIKit/UITable.h>
#import <UIKit/UITableColumn.h>
#import <UIKit/UITableCell.h>

#import "ToDoView.h"
#import "ToDoGroupEditView.h"
#import "ToDoDetailView.h"
#import "ToDoOrderByView.h"
#import "ToDoGroupView.h"
#import "ToDoSetDateView.h"
#import "ToDoGroupDetailView.h"
#import "ToDoPreferenceView.h"
#import "ToDoDeleteAfterView.h"

@class ToDoView;
@class ToDoGroupEditView;
@class ToDoDetailView;
@class ToDoOrderByView;
@class ToDoDeleteAfterView;

@class ToDoGroupView;
@class ToDoSetDateView;
@class ToDoGroupDetailView;
@class ToDoPreferenceView;
@class ToDoManager;
@class ToDo;

@interface MobileToDoListApplication : UIApplication {
	UIWindow *mainWindow;
	UIView *mainView;
	UINavigationBar *nav;
	UITransitionView *transitionView;
	UITable *viewTable;
	UITableColumn *viewTableCol;
	UIAlertSheet *betaInfoSheet;
	UIAlertSheet *changesSheet;
	UIAlertSheet *nextFuturesSheet;
	
	NSString *dirPath;
	NSString *filePath;
	NSString *groupFilePath;
	NSString *preferenceFilePath;
	
	ToDoManager *toDoManager;
	ToDoView *toDoView;
	ToDoGroupEditView *toDoGroupEditView;
	ToDoGroupDetailView *toDoGroupDetailView;
	ToDoDetailView *toDoDetailView;
	ToDoGroupView *toDoGroupView;
	ToDoOrderByView *toDoOrderByView;
	ToDoDeleteAfterView *toDoDeleteAfterView;
	ToDoSetDateView *toDoSetDateView;
	ToDoPreferenceView *toDoPreferenceView;
	
	BOOL editMode;
	
	NSXMLDocument *xmlDoc;
}

- (void) applicationWillTerminate;
- (void) applicationResume:(struct __GSEvent *) event;
- (void) applicationSuspend:(struct __GSEvent *) event;
- (void)updateBadge;
+ (MobileToDoListApplication *)sharedInstance;
- (void)showToDosWithTransition:(int)trans;
- (void)showToDoDetailsWithTransition:(int)trans;
- (void)showToDoGroupsWithTransition:(int)trans;
- (void)showToDoOrderByWithTransition:(int)trans;
- (void)showToDoDeleteAfterWithTransition:(int)trans;
- (void)showToDoPreferencesWithTransition:(int)trans;
- (void)showToDoGroupsEditWithTransition:(int)trans;
- (void)showToDoSetDateWithTransition:(int)trans;
- (void)showToDoGroupDetailWithTransition:(int)trans;
- (void)showBetaSheet;
- (void)showChangesSheet;
- (void)showNextFuturesSheet;

- (void)applicationDidFinishLaunching:(id)unused;
- (void)applicationWillSuspend;
- (void)alertSheet:(UIAlertSheet *)sheet buttonClicked:(int)button;
- (void)loadURL;
@end
